<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8" %>
<%@ include file="inc/taglibs.jsp" %>
<!DOCTYPE html>
<html lang="zh-cn">
<head>
    <%@ include file="inc/meta.jsp" %>
    <meta name="description" content="">
    <meta name="author" content="">
    <title>用户详情</title>
    <%@ include file="inc/css.jsp" %>
</head>
<body>

<div id="posts" class="wrapper">

    <%@ include file="inc/nav.jsp" %>

    <div id="page-wrapper">
        <div class="row">
            <div class="col-lg-12">
                <h1 class="page-header">用户列表</h1>
                <h4 style="margin-left: 10px;">——用户详情</h4>
            </div>
        </div>

        <div class="row">
            <div class="col-lg-12">
                <div class="panel panel-default">
                    <!-- /.panel-heading -->
                    <div class="panel-body">
                        <form class="form-horizontal">

                            <c:if test="${user.avatar != '' && user.avatar != null}">
                                <div style="position: absolute; top: 45px; right: 60px;">
                                    <img src="${user.avatar}" height="250px" width="250px" style="border: 1px solid black"/>
                                </div>
                            </c:if>

                            <div class="form-group">
                                <label class="col-sm-2 control-label">昵称:</label>

                                <div class="col-sm-4" style="padding-top: 6.5px;">
                                    ${user.nickName}
                                </div>
                            </div>

                            <div class="form-group">
                                <label class="col-sm-2 control-label">性别:</label>

                                <div class="col-sm-4" style="padding-top: 6.5px;">
                                    <c:if test="${user.sex == 0}">男</c:if>
                                    <c:if test="${user.sex == 1}">女</c:if>
                                </div>
                            </div>

                            <div class="form-group">
                                <label class="col-sm-2 control-label">新浪账号:</label>

                                <div class="col-sm-4" style="padding-top: 6.5px;">
                                    ${wbNum}
                                </div>
                            </div>

                            <div class="form-group">
                                <label class="col-sm-2 control-label">微信账号:</label>

                                <div class="col-sm-4" style="padding-top: 6.5px;">
                                    ${wxNum}
                                </div>
                            </div>

                            <div class="form-group">
                                <label class="col-sm-2 control-label">手机:</label>

                                <div class="col-sm-4" style="padding-top: 6.5px;">
                                    ${user.mobile}
                                </div>
                            </div>

                            <div class="form-group">
                                <label class="col-sm-2 control-label">QQ号码:</label>

                                <div class="col-sm-4" style="padding-top: 6.5px;">
                                    ${qqNum}
                                </div>
                            </div>

                            <div class="form-group">
                                <label class="col-sm-2 control-label">出生日期:</label>

                                <div class="col-sm-4" style="padding-top: 6.5px;">
                                    ${user.birthday}
                                </div>
                            </div>

                            <div class="form-group">
                                <label class="col-sm-2 control-label">标签:</label>

                                <div class="col-sm-4" style="padding-top: 6.5px;">
                                    ${tags}
                                </div>
                            </div>

                            <div class="form-group">
                                <div class="col-sm-12" style="text-align: center">
                                    <a href="backend/user/index" class="btn btn-primary" role="button">返回</a>
                                </div>
                            </div>
                        </form>
                    </div>
                    <!-- /.panel-body -->

                </div>

                <!-- /.panel -->
            </div>
        </div>

        <c:if test="${addressList.size() > 0}">
            <div class="row">
                <div class="col-lg-12">
                    <div class="panel panel-info">
                        <div class="panel-heading">收信地址</div>
                        <div class="panel-body">
                            <form class="form-horizontal">

                                <c:forEach var="n" items="${addressList}" varStatus="s">
                                    <div class="form-group">
                                        <label class="col-sm-2 control-label">联系人姓名:</label>

                                        <div class="col-sm-4" style="padding-top: 6.5px;">
                                                ${n.userName}
                                        </div>
                                    </div>

                                    <div class="form-group">
                                        <label class="col-sm-2 control-label">联系人电话:</label>

                                        <div class="col-sm-4" style="padding-top: 6.5px;">
                                                ${n.mobile}
                                        </div>
                                    </div>

                                    <div class="form-group">
                                        <label class="col-sm-2 control-label">详细地址:</label>

                                        <div class="col-sm-4" style="padding-top: 6.5px;">
                                                ${n.region.city.province.name}${n.region.city.name}${n.region.name}${n.description}
                                        </div>
                                    </div>

                                    <c:if test="${!s.last}">
                                        <hr/>
                                    </c:if>
                                </c:forEach>

                            </form>
                        </div>
                        <!-- /.panel-body -->

                    </div>

                    <!-- /.panel -->
                </div>
            </div>
        </c:if>

        <div class="row">
            <div class="col-lg-12">
                <div class="panel panel-info">
                    <div class="panel-heading">当前状态：<c:if test="${user.sealStatus == 0}">正常</c:if><c:if test="${user.sealStatus == 1}">封禁</c:if></div>
                    <div class="panel-body">
                        <form class="form-horizontal">

                            <c:forEach var="n" items="${sealInfoList}" varStatus="s">
                                <div class="form-group">
                                    <label class="col-sm-1 control-label"></label>

                                    <div class="col-sm-6" style="padding-top: 6.5px;">
                                            ${n.content}
                                        &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
                                            ${n.createTimeStr}
                                    </div>
                                </div>
                            </c:forEach>

                        </form>
                    </div>
                    <!-- /.panel-body -->

                </div>

                <!-- /.panel -->
            </div>
        </div>
    </div>
    <!-- /#page-wrapper -->

</div>
<!-- /#wrapper -->

<%@ include file="inc/footer.jsp" %>

</body>

</html>